<?php


namespace app\model\config;


use think\Model;
use think\model\concern\SoftDelete;

class CouponModel extends Model
{
    protected $name = 'coupon';
    protected $autoWriteTimestamp = true;

    use SoftDelete;
    protected $defaultSoftDelete = 0;

    public function setUseEndTimeAttr($value)
    {
        return strtotime($value);
    }

    public function getUseEndTimeAttr($value)
    {
        return date('Y-m-d H:i:s', $value);
    }
}